<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<jsp:include page="inc/css.jsp"></jsp:include>
<jsp:include page="inc/js.jsp"></jsp:include>
<script type="text/javascript">
        $(document).ready(function() {
            //建议在#imgDiv的父元素上加个overflow:hidden;的css样式
            $("input").uploadPreview({ width: 200, height: 200, imgDiv: "#imgDiv", imgType: ["bmp", "gif", "png", "jpg"] });
        });
    </script>
<form action="upload.do" method="POST" enctype="multipart/form-data">
	<input type="file" name="file" value="浏览"/>
	  <div style="width: 200px; height: 200px; overflow: hidden; border: 1px solid red;">
        <div id="imgDiv">
        </div>
    </div>
    <input type="submit" value="上传">
</form>